﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework;

namespace FUSE
{
    public class EndPlanet : FUSE.GalaxyComponent
    {
        public const float MIN_ANGLE = 180.0f;
        public const float MAX_ANGLE = 360.0f;

        private int points;

        public EndPlanet() : base()
        {
            points = 1;
        }

        public override void LoadContent(Microsoft.Xna.Framework.Graphics.Texture2D newTexture)
        {
            base.LoadContent(newTexture);
            this.ComponentBounds.radius = Math.Min(newTexture.Height, (newTexture.Width / 2));
        }

        public override void SetRenderPosition(float xCoord, float yCoord)
        {
            this.RenderPosition = new Vector2(xCoord, yCoord);
            this.ComponentBounds.centerPOS = new Vector2(xCoord + 
                (this.ComponentTexture.Width / 2), yCoord);
        }

        public override void SetCenterPosition(float xCoord, float yCoord)
        {
            this.ComponentBounds.centerPOS = new Vector2(xCoord, yCoord);
            this.RenderPosition = new Vector2(xCoord -
                (this.ComponentTexture.Width / 2), yCoord);
        }

        public int Points
        {
            get { return points; }
            set { points = value; }
        }
    }
}
